﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="BannerList.aspx.cs" Inherits="Course_BannerList" %>

<%@ Register Assembly="AspNetPager" Namespace="Wuqi.Webdiyer" TagPrefix="webdiyer" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>首页轮播信息</title>
     <link href="../../css/assets/css/bootstrap.min.css" rel="stylesheet" />
    <link href="../../css/admin.css" rel="stylesheet" />
    <script src="../../js/jquery-1.7.2.min.js"></script>
    <script src="../../css/assets/js/bootstrap.min.js"></script>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <div class="row">
                <div runat="server" id="divCondition">
                    <div class="col-lg-4 col-md-4 col-sm-6 colSpace">
                        首页轮播标题：
                    <br />
                        <asp:TextBox runat="server" ID="txtBannerName" CssClass="txtSize"></asp:TextBox>
                    </div>
                   
                  <div class="col-lg-4 col-md-4 col-sm-6 colSpace" style="margin-top: -2px">
                        <br />
             <asp:Button runat="server" ID="btnSelect" Text="查询" CssClass="btn btn-primary btnSize" OnClick="btnSelect_Click" />&nbsp;&nbsp;&nbsp;&nbsp;
             <asp:Label runat="server" CssClass="txtWarn" ID="lblWarn"></asp:Label>
                    </div>
                </div>
            </div>
            <br />
            <div>
                <asp:GridView  runat="server" ID="gridList" CssClass="table table-striped table-bordered table-hover" AutoGenerateColumns="False" DataKeyNames="BannerID" OnRowDeleting="gridList_RowDeleting" >
                    <Columns>
                        
                        <asp:BoundField DataField="BannerName" HeaderText="首页轮播标题" HeaderStyle-Width="35%"/> 
                         <asp:BoundField DataField="BannerLink" HeaderText="首页轮播链接" HeaderStyle-Width="45%" />
                        <asp:BoundField DataField="Sort" HeaderText="排序" />
                        
                        <%-- <asp:TemplateField HeaderText="状态">
                            <ItemTemplate>
                                <%#Eval("Status").ToString() == "1" ? "正常" : "禁用"%>
                            </ItemTemplate>
                        </asp:TemplateField>--%>
                        <asp:TemplateField HeaderText="操作">
                            <ItemTemplate>                              
           <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl='<%# "BannerEdit.aspx?BannerID="+Eval("BannerID")%>'>编辑</asp:HyperLink>&nbsp;&nbsp;
                <asp:LinkButton runat="server" ID="btnDel" OnClientClick="return confirm('确定删除吗？')" CommandName="Delete" CausesValidation="False">删除</asp:LinkButton>             
                            </ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                </asp:GridView>
            </div>
            <div class="pagerLayout">
                <webdiyer:AspNetPager ID="netPager" CssClass="pagerLayout" runat="server" FirstPageText="首页" LastPageText="尾页"
                    NextPageText="下一页" OnPageChanged="netPager_PageChanged" PrevPageText="上一页"
                    PageSize="15">
                </webdiyer:AspNetPager>
            </div>
        </div>
    </form>
</body>
</html>
